import { useParams } from "react-router-dom";

const News = () => {
    const params = useParams();
    const id = params.id;
    const name = params.name;
    return (
        <>
            <div>
                <p>Welcome, {name}, id is {id}.</p>
                <p>I am News.</p>
            </div>
        </>
    )
}

export default News;